<!--Container-->
<div class="site-wrap3 box-detail clearfix"> 
	<!--Noi dung chinh-->
	<div class="containerLeft" id="containerLeft">
		<div class="boxContent">
			<div class="boxCtTop clearfix">
				<ul class="toolsBar clearfix">
					<li class="pull-left"><a href="#" title="Quan tâm"><i class="icon-bookmark"></i></a></li>
					<li class="pull-left"><a href="#" title="Thích"><i class="icon-thumbs-up"></i></a></li>
					{if 'admin news edit'|check_perm}<li class="pull-left"><a class="hasText Button color1 large ajax pull-left" href="{'news/edit/%d'|l:$news.news_id}">Sửa nội dung</a></li>{/if}
					<li class="pull-right"><a href="http://{$smarty.server.HTTP_HOST}{$smarty.server.REDIRECT_URL}" class="btnFbShare" title="Share"><i class="icon-share"></i></a></li>
					{if $news.news_countdown>0}
					<li class="pull-right">
						<p class="pull-left title">Còn lại</p>
						<div id="clock" class="pull-left countdown clearfix" data-date="{$news.news_countdown}">
							<div class="countdown-numbers clearfix">
								<p> Tuần <span id="weeks"></span> </p>
								<!--<div class="space">:</div>-->
								<p> Ngày <span id="daysLeft"></span> </p>
								<!--<div class="space">:</div>-->
								<p> Giờ <span id="hours"></span> </p>
								<!--<div class="space">:</div>-->
								<p> Phút <span id="minutes"></span> </p>
								<!--<div class="space">:</div>-->
								<p> Giây <span id="seconds"></span> </p>
							</div>
						</div>
					</li>
					{/if}
				</ul>
			</div>
			<!--Anh 1-->
			<div class="imgDetailArticle" id="test"> 
				<!--<p><img alt="" src="../img/grey.gif" id="target" data-original="media/img/imgdetail-1.jpg" /></p>-->
				{if $news.news_youtube_id==''}
				<p style="text-align:center"><img alt="" src="{$news.news_thumb|thumb:'crop620x400'}" id="target"/></p>
				{else}
				<iframe width="620" height="400" src="//www.youtube.com/embed/{$news.news_youtube_id}?wmode=transparent" frameborder="0" allowfullscreen></iframe>
				{/if}
				<!--Title anh-->
				<h4>{$news.news_title}</h4>
				{*<p> <a class="fancybox" href="img/1_b.jpg" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"><img src="img/1_s.jpg" alt="" /></a> <a class="fancybox" href="img/1_b.jpg" data-fancybox-group="gallery" title="Etiam quis mi eu elit temp"><img src="img/1_s.jpg" alt="" /></a> <a class="fancybox" href="img/1_b.jpg" data-fancybox-group="gallery" title="Cras neque mi, semper leon"><img src="img/1_s.jpg" alt="" /></a> <a class="fancybox" href="img/1_b.jpg" data-fancybox-group="gallery" title="Sed vel sapien vel sem uno"><img src="img/1_s.jpg" alt="" /></a> </p>*}
				
				<div class="newsContent">
					{$news.news_content}
					{if $news.news_source_url!=''}
					<p>Theo <a href="{$news.news_source_url}" rel="nofollow"><strong><em>{$news.news_source}</em></strong></a></p>
					{/if}
				</div>
			</div>
			{*
			<div class="box-slide-rel">
				<div class="flexcarousel02 carousel">
					<ul class="slides">
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
						<li> <a href="img/1_b.jpg" class="avatar fancybox" data-fancybox-group="gallery" title="Lorem ipsum dolor sit amet"> <img src="img/1_s.jpg" alt="chan" title="Chắn online"> </a></li>
					</ul>
				</div>
			</div>
			*}
		</div>
		<div class="boxContent">
			<div class="boxCtTop">
				<h3>Comments</h3>
			</div>
			<div class="commentDetailArticle">
				<div class="comments-area">
					<div class="fb-comments" data-href="http://{$smarty.server.HTTP_HOST}{$smarty.server.REDIRECT_URL}" data-width="630"></div>
				</div>
			</div>
		</div>
		<!--box anh hot-->
		{if $aFrNews}
		<div class="boxContent">
			<div class="boxCtTop">
				<h3>Tin bạn bè đã đọc</h3>
			</div>
			<div class="hotNenxemPhoto-2 clearfix">
			{foreach from=$aFrNews item=n}
				<div class="item-relative">
					<div class="img-item"> <a href="{'news/detail/%d'|l:$n.news_id}"><img src="{$n.news_thumb|thumb:'crop100x100'}" /> </a></div>
					<div class="info-r">
						<h4><a href="{'news/detail/%d'|l:$n.news_id}">{$n.news_title}</a></h4>
					</div>
				</div>
			{/foreach}
			</div>
		</div>
		{/if}
	</div>
	<div class="containerRight">
		<div class="boxContent">
			<a href="http://www.facebook.com/we.playlive1" target="_blank"><img src="{'files/banner/banner-the-under-250x300.jpg'|l}" /></a>
		</div>
		<!--Thong tin album-->
		<div class="boxContent">
			<div class="boxCtTop with-shadow">
				<h3>Tin liên quan</h3>
			</div>
			<div class="newsRelative">
				<div class="pinGridWrapper group">
					<div class="ajax Grid Module group" style="display: block;">
						<div id="thumbnail-sm" class="clearfix group">
							{foreach from=$newsRelate item=n}
							<div class="item-r activeItem group" tabindex="1">
								<div class="boardPinsGrid ajax Pin Module"><i class="show-detail">Chi tiết</i><a href="{'news/detail/%d'|l:$n.news_id}" class="boardPinsGridPin"> <img src="{$n.news_thumb|thumb:'w105'}" /> </a> </div>
							</div>
							{/foreach}
						</div>
					</div>
				</div>
			</div>
			<!--<div class="boxBottom"> <a href="javascript:void(0)" class="btn-follow btn-relative"><i class="icon-ok"></i> <span class="txt-follow">Dõi theo</span><span class="txt-unfollow">Ngừng dõi theo</span></a> </div>--> 
		</div>
		<div class="boxContent">
			<div class="boxCtTop">
				<h3>Người đã đọc tin</h3>
			</div>
			<div class="memRead clearfix">
				<ul>
					{foreach from=$aReader item=r key=id}
					<li><a href="{'user/home/%d'|l:$id}"> <img title="{$r.fullname}" src="{$r.avatar|thumb:'crop40x40'}" /> </a></li>
					{/foreach}
				</ul>
			</div>
		</div>
	</div>
	<!--/ End noi dung chinh--> 
	<!--btn len dau trang-->
	<div class="btnUpTop"><a href="#" title="Lên đầu trang">Lên đầu trang</a></div>
</div>

<script src="{'js/jquery-ui.min.js'|ltpl}" type="text/javascript" charset="utf-8"></script> 
<script src="{'js/jquery.slimscroll.min.js'|ltpl}" type="text/javascript" charset="utf-8"></script> 
<script src="{'js/jquery.countdown.js'|ltpl}" type="text/javascript" charset="utf-8"></script> 
<script src="{'js/jquery.masonry.min.js'|ltpl}" type="text/javascript" charset="utf-8"></script>
{literal}
<script>
$(function(){
  $('.pinGridWrapper').slimScroll({
      height: '459px',
			size:'10px'
  });
  
  var $container = $('#thumbnail-sm');
	$container.imagesLoaded( function(){
		$container.masonry({
			isAnimated: true,
			itemSelector: '.item-r',
  		columnWidth: 115
  	});
	});
});
</script> 

<script type="text/javascript" charset="utf-8">
$(function() {
	if ($('div#clock').length>0){
      var finished = false;
      
      function callback(event) {
  		  $this = $(this);
  			switch(event.type) {
  				case "seconds":
  				case "minutes":
  				case "hours":
  				case "days":
  				case "weeks":
  				case "daysLeft":
					$this.find('span#'+event.type).html(event.value);
					if(finished) {
						$this.fadeTo(0, 1);
						finished = false;
					}
					break;
  				case "finished":
		            $this.fadeTo('slow', .5);
		            finished = true;
  					break;
  			}
      	}
		$('div#clock').countdown(parseInt($('div#clock').attr('data-date'))*1000, callback);
	}
});
</script> 
{/literal}